from collections import deque
q = deque(['a', 'b', 'c'])
print(q)
q.append('x')
print(q)
q.appendleft('y')
print(q)
q.pop()
print(q)

a=[1,2,3,4,5]
c=a.pop(2)
print(a)
print(c)
